import java.awt.CardLayout;
import java.awt.Color;
import java.awt.Component;
import java.awt.Font;
import java.awt.Frame;
import java.awt.GridBagConstraints;
import java.awt.GridBagLayout;
import java.awt.GridLayout;
import java.awt.Insets;
import java.awt.Panel;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.DefaultComboBoxModel;
import javax.swing.JButton;
import javax.swing.JComboBox;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JPasswordField;
import javax.swing.JSpinner;
import javax.swing.JTextField;
import javax.swing.SwingConstants;


public class realMain extends JFrame {
	
	public CardLayout cardLayoutTicket;
	public Panel cardTicketPanel;
	
	
	public realMain() {
		
		JFrame frame = new JFrame("main");
		
		
//grid
		GridBagLayout gbl_panel = new GridBagLayout();
		gbl_panel.columnWidths = new int[]{164, 3000, 0};
		gbl_panel.rowHeights = new int[]{0, 3000, 0};
		gbl_panel.columnWeights = new double[]{0.0, 2.0, Double.MIN_VALUE};
		gbl_panel.rowWeights = new double[]{0.0, 2.0, Double.MIN_VALUE};
		frame.setLayout(gbl_panel);
		
		
//panel_1		Login
		Login l = new Login();
		
		GridBagConstraints gbc_panel_1 = new GridBagConstraints();
		gbc_panel_1.insets = new Insets(0, 0, 5, 5);
		gbc_panel_1.fill = GridBagConstraints.BOTH;
		gbc_panel_1.gridx = 0;
		gbc_panel_1.gridy = 0;
		frame.add(l.login(), gbc_panel_1);
		
				
//MatchPanel		MatchScehdule
		MatchScehdule ms = new MatchScehdule();
		
		GridBagConstraints gbc_MatchPanel = new GridBagConstraints();
		gbc_MatchPanel.insets = new Insets(0, 0, 5, 0);
		gbc_MatchPanel.fill = GridBagConstraints.BOTH;
		gbc_MatchPanel.gridx = 1;
		gbc_MatchPanel.gridy = 0;
		frame.add(ms.matchschehdule(), gbc_MatchPanel);
		
//MenuPanel		Menu
		Menu m = new Menu();
		
		GridBagConstraints gbc_MenuPanel = new GridBagConstraints();
		gbc_MenuPanel.insets = new Insets(0, 0, 0, 5);
		gbc_MenuPanel.fill = GridBagConstraints.BOTH;
		gbc_MenuPanel.gridx = 0;
		gbc_MenuPanel.gridy = 1;
		frame.add(m.menu(), gbc_MenuPanel);
	
		
		
//TicketPanel    Main
		
		GridBagConstraints gbc_ticketPanel = new GridBagConstraints();
		gbc_ticketPanel.fill = GridBagConstraints.BOTH;
		gbc_ticketPanel.gridx = 1;
		gbc_ticketPanel.gridy = 1;
		frame.add(ms.mp.mainpanel(), gbc_ticketPanel);
		
		
//frame
		frame.setVisible(true);
		frame.setSize(1000, 500);
		frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);


	}
	
	
//main for test
	public static void main(String[] args) {
		realMain main = new realMain();
	}
	
}

